const path = require('path')
// const resolve = dir => path.resolve(dir)
module.exports = {
    publicPath: "./", //修改资源目录的路径
    lintOnSave: false,
    //代理原理 使用了一个中间件 叫做 http-proxy-middleware
    devServer: {
        proxy: {
            "/api": {
                target: process.env.VUE_APP_BASE_URL, //目标服务器
                pathRewrite: { //路径重写
                    "^/api": ""
                }
            }
        }
    }
}